<template>
    <view class="page container pad-t-10" v-if="info">
        <view class="order-info flex bac-color-fff">
            <view class="left">

            </view>
            <view class="flex-1 mar-l-8">
                <view class="font-size-14 font-bold">
                    <text>用户信息</text>
                </view>
                 <view class="font-size-14 mar-t-5 font-color-555">
                    <text>预约人：{{info.link_man}}</text>
                </view>
                <view class="font-size-14 mar-t-5 font-color-555">
                    <text>预约时间：{{transformTime(info.start_time)}}</text>
                </view>
                <view class="font-size-14 mar-t-5 font-color-555">
                    <text>咨询类型：{{info.tag}}</text>
                </view>
            </view>
        </view>
        <view class="feed-title flex">
            <view class="left"></view>
            <view class="flex-1 mar-l-8 font-size-14 font-bold">
                反馈信息
            </view>
        </view>
        <view class="feedback-info bac-color-fff over-hid pos-rel">
            <textarea name="" id="" cols="30" rows="10" placeholder="输入反馈内容"  v-model="back_info"></textarea>
        </view>
        <view class="footer-btn" @click="subFeedBack">
			<text class>提交反馈</text>
		</view>
    </view>
</template>

<script>
import {  confirmServer,myOrdersInfo } from '@/utils/http'
export default {
    data(){
        return {
            info:'',
            back_info:'',
            order_no:''
        }
    },
    methods:{
        myOrdersInfo(){
            myOrdersInfo({order_no:this.order_no}).then(res=>{
                if(res){
                    this.info = res;
                }
            })
        },
        subFeedBack(){
            if(this.back_info =='') {
                this.errorToShow('请填写反馈信息');
                return ;
            }
            confirmServer({order_no:this.order_no,back_info:this.back_info}).then(res=>{
                    if(res){
                        this.redirect('/pages/counselor/order')
                    }
            })
        }
    },
    onLoad(option){
        this.order_no = option.order_no;
        this.myOrdersInfo();
    }
}
</script>

<style scoped>
page,.page{
    background-color: #F1F1F1;
}
.order-info{
    padding: 10px 7px 24px 7px;
    border-radius: 5px;
}
.feed-title{
    padding: 10px 7px ;
}
.order-info .left,.feed-title .left{
    width: 2px;
    height: 14px;
    margin-top: 3px;
    background-color: #2C86F0;
}
.feedback-info {
    width: 100%;
     box-sizing: border-box;
}
.feedback-info textarea{
    width: 100%;
    padding: 10px;
     box-sizing: border-box;

}

.footer-btn {
	height: 45px;
	width: 230px;
	line-height: 45px;
	margin: 0 auto;
}
.footer-btn text {
	display: block;
	margin-top: 30px;
	margin-bottom: 40px;
	background-color: #0088ff;
	border-radius: 5px;
	color: #ffffff;
	text-align: center;
	font-size: 15px;
	/* font-weight: bold; */
}
</style>